how to use the midsegment theorem